<?php

namespace app\common\model;

use think\Model;

class System extends Model
{
	//根据上级ID获取配置信息
	public static function get_config_by_code($code)
	{
		return self::where(['status'=>1,'pid'=>self::where(['status'=>1,'code'=>$code])->value('id')])->order('sort','ASC')->column('value','code');
	}
}